package com.gzz.orchid.common.boot.mybatis.conditices.section;

import lombok.val;

/**
 * @author higmd
 */
public interface ICompare<Children, R> {
    default Children eq(R column, Object val) {
        return this.eq(true, column, val);
    }

    Children eq(boolean flg, R column, Object val);

    default Children ne(R column, Object val) {
        return this.ne(true, column, val);
    }

    Children ne(boolean flg, R column, Object val);

    default Children gt(R column, Object val) {
        return this.gt(true, column, val);
    }

    Children gt(boolean flg, R column, Object val);

    default Children ge(R column, Object val) {
        return this.ge(true, column, val);
    }

    Children ge(boolean flg, R column, Object val);

    default Children lt(R column, Object val) {
        return this.lt(true, column, val);
    }

    Children lt(boolean flg, R column, Object val);

    default Children le(R column, Object val) {
        return this.le(true, column, val);
    }

    Children le(boolean flg, R column, Object val);

    default Children between(R column, Object val1, Object val2) {
        return this.between(true, column, val1, val2);
    }

    Children between(boolean flg, R column, Object val1, Object val2);

    default Children notBetween(R column, Object val1, Object val2) {
        return this.notBetween(true, column, val1, val2);
    }

    Children notBetween(boolean flg, R column, Object val1, Object val2);

    default Children like(R column, Object val) {
        return this.like(true, column, val);
    }

    Children like(boolean flg, R column, Object val);

    default Children notLike(R column, Object val) {
        return this.notLike(true, column, val);
    }

    Children notLike(boolean flg, R column, Object val);

    default Children notLikeLeft(R column, Object val) {
        return this.notLikeLeft(true, column, val);
    }

    Children notLikeLeft(boolean flg, R column, Object val);

    default Children notLikeRight(R column, Object val) {
        return this.notLikeRight(true, column, val);
    }

    Children notLikeRight(boolean flg, R column, Object val);

    default Children likeLeft(R column, Object val) {
        return this.likeLeft(true, column, val);
    }

    Children likeLeft(boolean flg, R column, Object val);

    default Children likeRight(R column, Object val) {
        return this.likeRight(true, column, val);
    }

    Children likeRight(boolean flg, R column, Object val);

    default Children or() {
        return this.or(true);
    }

    Children or(boolean flg);
    default Children in(R column, Object...val) {
        return this.in(true, column, val);
    }

    Children in(boolean flg,R column, Object... val);
}
